package com.doublefish.doublefishrobot.ui.home.adapter;

import android.content.Context;
import android.view.View;
import android.widget.TextView;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.doublefish.doublefishrobot.R;
import com.doublefish.doublefishrobot.ui.home.bean.ModeSettingBean;

import java.util.List;

/**
 * 作者:dugaofeng on 2024/10/18 17:00
 */
public class ModeCustomListAdapter extends BaseQuickAdapter<ModeSettingBean, ModeCustomListAdapter.ModeCustomListHolder> {

    private Context mContext;

    public ModeCustomListAdapter(Context context, List<ModeSettingBean> data) {
        super(R.layout.item_product_type_cell, data);
        mContext = context;
    }

    @Override
    protected void convert(ModeCustomListAdapter.ModeCustomListHolder helper, ModeSettingBean item) {
        helper.nameTv.setText(item.getName());
    }


    class ModeCustomListHolder extends BaseViewHolder {
        TextView nameTv;

        public ModeCustomListHolder(View view) {
            super(view);

            nameTv = view.findViewById(R.id.tv_text);
        }
    }
}
